package com.cloud.cmt.usermanage.service;

import com.cloud.cmt.usermanage.entity.UserInfo;
import org.springframework.data.domain.Page;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.query.Param;
import org.springframework.data.rest.core.annotation.RepositoryRestResource;

import java.util.List;

/**
 * Created by Administrator on 2017/10/21.
 */
@RepositoryRestResource(path = "user")
public interface UserInfoRepository extends JpaRepository<UserInfo, Long> {
    List<UserInfo> findByUserName(String name);
//    @Query(value = "select u from UserInfoVO u where u.employee.name like %:value% OR u.userName like  %:value% ")
//    Page<UserInfo> getUserInfo(@Param("value") String value);
}
